package sv.com.seguros.dto.ctg;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

@Entity
@Table(name = "ctg_plan")
public class CtgPlan implements Serializable{

	private static final long serialVersionUID = -185330561072749170L;
	
	@Id
	@Column(name = "ctg_plan_id")
	@GeneratedValue(strategy = GenerationType.IDENTITY)
	private Long ctgPlanId;
	@Column(name = "ctg_plan_nombre", nullable = false, length = 100)
	private String ctgPlanNombre;
	@Column(name = "ctg_plan_activo", nullable = false, length = 1)
	private String ctgPlanActivo = "1";
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "ctg_ase_id", nullable = false)
	private CtgAseguradora ctgAseguradora;
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "ctg_tseg_id", nullable = false)
	private CtgCatalogo ctgTipoSeguro;

	public Long getCtgPlanId() {
		return ctgPlanId;
	}

	public void setCtgPlanId(Long ctgPlanId) {
		this.ctgPlanId = ctgPlanId;
	}

	public String getCtgPlanNombre() {
		return ctgPlanNombre;
	}

	public void setCtgPlanNombre(String ctgPlanNombre) {
		this.ctgPlanNombre = ctgPlanNombre;
	}

	public String getCtgPlanActivo() {
		return ctgPlanActivo;
	}

	public void setCtgPlanActivo(String ctgPlanActivo) {
		this.ctgPlanActivo = ctgPlanActivo;
	}

	public CtgAseguradora getCtgAseguradora() {
		return ctgAseguradora;
	}

	public void setCtgAseguradora(CtgAseguradora ctgAseguradora) {
		this.ctgAseguradora = ctgAseguradora;
	}

	public CtgCatalogo getCtgTipoSeguro() {
		return ctgTipoSeguro;
	}

	public void setCtgTipoSeguro(CtgCatalogo ctgTipoSeguro) {
		this.ctgTipoSeguro = ctgTipoSeguro;
	}
}
